﻿using System.Configuration;
using PSE.Updater.Common.Providers;

namespace PSE.Updater.Common.Configurations.Server
{
    public class ProviderConfigurationElement : ConfigurationElement
    {
        /// <summary>
        /// Type do provider
        /// </summary>
        [ConfigurationProperty("type", IsKey = true, IsRequired = true)]
        public ProviderType Type
        {
            get { return (ProviderType)this["type"]; }
            set { this["type"] = value; }
        }

        /// <summary>
        /// Lista de Observers configurados
        /// </summary>
        [ConfigurationProperty("watchers", IsDefaultCollection = true)]
        public WatcherConfigurationElementCollection Watchers
        {
            get { return (WatcherConfigurationElementCollection)base["watchers"]; }
        }
    }
}
